package pers.bbw.crr.service;

import com.github.pagehelper.PageInfo;
import org.springframework.web.multipart.MultipartFile;
import pers.bbw.crr.dto.EquipmentSearchDto;
import pers.bbw.crr.entity.Equipment;

/**
 * equipmentService接口
 *
 * @author bbw
 * @date 2024-12-13
 */
public interface EquipmentService {
    /**
     * 查询equipment
     *
     * @param id equipment主键
     * @return equipment
     */
    Equipment selectEquipmentById(int id);

    /**
     * 查询equipment列表
     *
     * @param equipment equipment
     * @return equipment集合
     */
    PageInfo<Equipment> selectEquipmentList(EquipmentSearchDto dto);

    /**
     * 新增equipment
     *
     * @param equipment equipment
     * @return 结果
     */
    void insertEquipment(Equipment equipment, MultipartFile file);

    /**
     * 修改equipment
     *
     * @param equipment equipment
     * @return 结果
     */
    void updateEquipment(Equipment equipment, MultipartFile file);

    /**
     * 批量删除equipment
     *
     * @param ids 需要删除的equipment主键集合
     * @return 结果
     */
    int deleteEquipmentByIds(int[] ids);

    /**
     * 删除equipment信息
     *
     * @param id equipment主键
     * @return 结果
     */
    int deleteEquipmentById(int id);
}
